<style>
    .dropdown-menu {
        max-height: 303px;
    }
</style>
<section class="content">
    <div class="row">
        <div class="col-xs-12">
            <div class="box">
                <div class="box-header">
                    <input type="checkbox" style="margin-left: 2%;" data-ng-model="info.isShowOnline"
                           ng-true-value="true" ng-false-value="false" ng-click="planList();"/>显示已上线项目
                    <img src="/beetle/image/icon_plus-box.png" ng-if="info.modifiAble"
                         style="cursor: pointer;margin-left: 2%;" ng-click="add();">
                    <i class="fa fa-question-circle" style="margin-left: 20%;"></i><a ng-click="goHelp();" style="cursor: pointer;">紧急项目操作流程</a>
                </div>
                <div class="box-body">
                    <input type="search" ng-model="search.plan_name" style="width: 220px;"
                           placeholder="Search Plan Name Here..."/>
                    <br>
                    <br>
                    <table class="table table-hover table-bordered">
                        <thead>
                        <tr>
                            <th width="5%">
                                项目名称
                            </th>
                            <th width="5%">
                                bug号
                            </th>
                            <th width="5%">
                                需求号
                            </th>
                            <th width="5%">
                                预计上线日期
                            </th>
                            <th width="5%">
                                项目负责人
                            </th>
                            <th colspan="2" width="5%">
                                测试负责人
                            </th>
                            <th width="5%">
                                状态
                            </th>
                            <th width="2%">
                                操作
                            </th>
                        </tr>
                        </thead>
                        <tbody>
                        <tr ng-repeat="i in info.planList |filter:search |paging:page.index:page.size">
                            <td>
                                <a ng-show="i.notCreateProCount == 0" href="javascript:void(0);"
                                   ng-click="projectInfo(i.plan_id)">
                                    {{i.plan_name}}
                                </a>
                                <span ng-show="i.notCreateProCount != 0">{{i.plan_name}}</span>
                            </td>
                            <td>
                                {{i.bug_num}}
                            </td>
                            <td>
                                {{i.need_num}}
                            </td>
                            <td>
                                {{i.expect_release_date}}
                            </td>
                            <td>{{i.PM_name}}</td>
                            <td>
                                <span ng-if="!i.modifyTestUser">{{i.test_head_name}}</span>
                                <input ng-if="i.modifyTestUser" type="text" ng-model="i.testUserInfo" uib-typeahead="user as user.realname for user in info.qaList | filter:{realname:$viewValue}|limitTo:15" typeahead-template-url="selectTemplate.html" class="form-control" typeahead-show-hint="true" typeahead-min-length="0" typeahead-select-on-blur="true">
                            </td>
                            <td>
                                <i ng-if="!i.modifyTestUser" class="glyphicon glyphicon-edit" data-ng-click="updateTestUser(i);" uib-popover="修改测试负责人" popover-trigger="mouseenter" style="font-size: 20px;"></i>
                                <i ng-if="i.modifyTestUser" class="glyphicon glyphicon-floppy-disk" data-ng-click="updateTestUser(i);" uib-popover="保存测试负责人" popover-trigger="mouseenter" style="font-size: 20px;"></i>
                            </td>
                            <td>
                                <span ng-if="i.notCreateProCount == 0">{{getStatusDesc(i.plan_status)}}</span>
                                <span ng-if="i.notCreateProCount != 0">
                                    <img style="width: 15px;height: 15px;vertical-align:baseline;"
                                         src="/beetle/image/loading.gif"/>
                                    初始化中,请稍候......
                                </span>

                            </td>
                            <td ng-if="info.modifiAble">
                                <i class="glyphicon glyphicon-trash" data-ng-click="del(i.plan_id);" uib-popover="删除项目"
                                   popover-trigger="mouseenter" style="font-size: 20px;"></i>
                            </td>
                        </tr>
                        </tbody>
                    </table>
                </div>
                <uib-pagination total-items="info.planList|filter:search|size" ng-model="page.index"
                                max-size="5"
                                previous-text="上一页"
                                next-text="下一页"
                                first-text="首页"
                                last-text="尾页"
                                items-per-page="page.size"
                                class="pagination-sm pull-right" boundary-links="true"></uib-pagination>
            </div>
        </div>
    </div>
</section>